﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="wfBuscarDocumentoTributario.aspx.cs" Inherits="WebGustozzi.ModuloVentas.ReporteVentas.wfBuscarDocumentoTributario" %>
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>Aplicación Web Gustozzi</title>
    <link href="//App_Themes/SkinFile/StyleSheet.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="../SCRIPT/ManejarControles.js"></script> 
    <script type="text/javascript" src="../SCRIPT/DialogosMaster.js"></script> 
     <script type="text/javascript">
         if (window.dialogArguments) {
             window.opener = window.dialogArguments;
         }
     </script>

     <script type="text/javascript" language="javascript">
         function AbrirModalPopup(nombrePagina, ancho, alto) {
             var atributos = 'dialogWidth:' + ancho + 'px' + ';dialogHeight:' + alto + 'px' + ';status:no;resizable:no;scroll:yes;center:yes';
             window.showModalDialog(nombrePagina, self, atributos);
             return false;
         }

         if (window.dialogArguments) {
             window.opener = window.dialogArguments;
         }

         function BuscarCliente() {
             AbrirModalPopup('wfBuscarCliente.aspx', 750, 400);
         }

    </script>
    <style type="text/css">
        .TitlebarLeft
        {
            margin-left: 40px;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="ScriptManager2" runat="server"></asp:ScriptManager>
    <asp:UpdatePanel ID="UpdatePanel1" runat="server"><contenttemplate> 
      <div class="popup_Container">
        <div class="popup_Titlebar" id="PopupHeader">
            <div class="TitlebarLeft">            
                <%--Titulo--%>
                  <table style="width:100%" cellpadding="0" cellspacing="0" border="0">
                    <tr>
                        <td >
                            <asp:Label id="lblTarea" runat="server" Text=":: CONSULTAR DOCUMENTO TRIBUTARIO" 
                                SkinID="labelTitulo"></asp:Label>
                        </td>
                    </tr>    
                    <tr>
                        <td style="HEIGHT: 10px"></td>
                    </tr>
                </table>
            </div>
            <div class="TitlebarRight" onclick="cancel();">
            </div>
        </div>
        <div class="popupBusqueda">
        <div id="contenedor4">
                <asp:HiddenField ID="hdf_InicioGrilla" runat="server"/>
               
                         <%--DATOS DE BUSQUEDA--%>
            <table style="width:100%" cellpadding="0" cellspacing="0" border="0" class="tdmarcoTitulo">
                <tr>
                    <td class="tdfondoTitulo" style="width:100%; HEIGHT: 18px" align="left" colspan="11">
                        <asp:Label ID="Label1" runat="server" SkinID="labelsubTituloSkin"  Text=" :: Datos de Búsqueda" Width="230px"></asp:Label>
                    </td>
                </tr>
                <tr>
                    <td style="HEIGHT: 5px" colspan="11"></td>
                </tr>  
                <tr>
                    <td style="width:3px; height: 26px;">             
                    </td>
                    <td style="width:100px">                
                        <asp:Label ID="Label6" runat="server" Text="Tipo Doc." SkinID="labelTextSkin"></asp:Label>       
                    </td>            
                    <td style="width:590px" colspan = "5">
                        <asp:DropDownList ID="ddlTipDoc" runat="server" SkinID="DropDownListTextSkin" 
                            Width="120px" AppendDataBoundItems="True">
                            <asp:ListItem Value="0">--Todos--</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                    <td ></td>            
                    <td ></td>                                    
                    <td >
                    </td>             
                    <td style="width:20px; height: 26px;">                
                    </td>
                </tr>
                <tr>
                    <td style="width:3px; height: 26px;">             
                        &nbsp;</td>
                    <td style="width:80px">                
                        <asp:Label ID="Label2" runat="server" Text="Nro. Documento" SkinID="labelTextSkin"></asp:Label>       
                    </td>            
                    <td style="width:100px">
                        <asp:TextBox ID="txtNumero" runat="server" Width="90px" SkinID="CajaTextoSkin"></asp:TextBox>                       
                    </td>
                    <td style="width:20px">                
                    </td>            
                    <td style="width:180">
                        <asp:Label ID="Label3" runat="server" Text="Fecha de Emisión:   Desde" SkinID="labelTextSkin"></asp:Label>
                        <asp:TextBox ID="txtFecIni" runat="server" Width="70px" SkinID="CajaTextoSkin"></asp:TextBox>
                        <asp:Imagebutton ID="imgFecIni" runat="server" 
                            ImageUrl="~/imagenes/calendario_semana.png" />
                        <asp:CalendarExtender ID="CalendarExtender1" runat="server" 
                            TargetControlID="txtFecIni" PopupButtonID="imgFecIni">
                        </asp:CalendarExtender>
                        <asp:MaskedEditExtender ID="MaskedEditExtender1" runat="server" TargetControlID="txtFecIni" Mask="99/99/9999" MaskType="Date">  </asp:MaskedEditExtender>
                    </td>
                    <td style ="width:10px">                
                    </td>            
                    <td style="width:150">
                        <asp:Label ID="Label4" runat="server" Text="Hasta" SkinID="labelTextSkin"></asp:Label>
                        &nbsp;<asp:TextBox ID="txtFecfin" runat="server" Width="70px" SkinID="CajaTextoSkin"></asp:TextBox>
                        <asp:Imagebutton ID="imgFecFin" runat="server" ImageUrl="~/imagenes/calendario_semana.png" />   
                        <asp:CalendarExtender ID="CalendarExtender2" runat="server" 
                            TargetControlID="txtFecfin" PopupButtonID="imgFecFin"></asp:CalendarExtender>         
                        <asp:MaskedEditExtender ID="MaskedEditExtender2" runat="server" TargetControlID="txtFecFin" Mask="99/99/9999" MaskType="Date">  </asp:MaskedEditExtender>
                    </td>                        
                    <td>                
                    </td>            
                    <td>
                    </td>                                    
                    <td>
                    </td>              
                    <td style="width:20px; height: 26px;">                
                    </td>
                </tr>

                <tr>
                    <td style="width:3px; height: 26px;">             
                    </td>
                    <td style="width:80px">                
                        <asp:Label ID="Label5" runat="server" Text="Cliente" SkinID="labelTextSkin"></asp:Label>       
                    </td>            
                    <td style="width:590px" colspan = "5">
                        <asp:TextBox ID="txtCodCliente" runat="server" Width="60px" 
                            SkinID="CajaTextoBloqueadoSkin" AutoPostBack="True" 
                            ontextchanged="txtCodCliente_TextChanged"></asp:TextBox>                       
                        <asp:TextBox ID="txtNombreCliente" runat="server" Width="350px" 
                            SkinID="CajaTextoBloqueadoSkin" style="margin-top: 0px"></asp:TextBox>                                       
                        <asp:ImageButton ID="imbBuscar" runat="server" 
                            ImageUrl="~/imagenes/bn_buscar.png" ToolTip="Buscar Cliente" OnClientClick="BuscarCliente()"
                            />              
                    </td>
                    <td style ="width:5px"></td>            
                    <td style ="width:20px">
                        <asp:ImageButton ID="imbFiltrar" runat="server" 
                            ImageUrl="~/imagenes/bn_filtrar.jpg" onclick="imbFiltrar_Click" />
                    </td>                                    
                    <td style ="width:80px" >
                    </td>             
                    <td style="width:20px; height: 26px;">                
                    </td>
                </tr>
                <tr>
                    <td style="HEIGHT: 5px" colspan="11"></td>
                </tr>                        
            </table> 
            <table>        
                <tr>
                    <td style="HEIGHT: 10px"></td>
                </tr>
            </table>
            <%--LISTADO DE DOCUMENTOS TRIBUTARIO--%>
            <TABLE style="WIDTH: 100%" cellSpacing=0 cellPadding=0>
                <TBODY>
                    <TR>
                        <TD style="HEIGHT: 18px" class="tdfondoTitulo" colSpan=7>
                            <asp:Label id="Label10" runat="server" Text=":: Listado de Documentos Tributario" 
                                SkinID="labelsubTituloSkin" Width="368px"></asp:Label>
                        </TD>
                    </TR>
                    <TR>
                        <TD class="tdmarcoTitulo">
                            <DIV style="WIDTH: 100%; HEIGHT: 150px" id="scrollDivPlanes" class="divGVForm">
                                <asp:GridView id="grvListaDocTri" runat="server" SkinID="gridviewSkin" 
                                    AutoGenerateColumns="False" AllowPaging="True" ShowHeaderWhenEmpty="True" 
                                    onrowdatabound="grvListaDocTri_RowDataBound">
                                <Columns>
                                    <asp:TemplateField>
                                        <ItemTemplate><asp:Label ID="lblItem" runat="server" Text='<%#Convert.ToInt32(DataBinder.Eval(Container, "DataItemIndex")) + 1%>'></asp:Label></ItemTemplate>
                                        <ItemStyle Width="4%" />
                                    </asp:TemplateField>
                                    <asp:BoundField HeaderText="TIPO DOC." DataField="TipoDoc">
                                        <ItemStyle Width="10%" />
                                    </asp:BoundField>
                                    <asp:BoundField HeaderText="NRO. DOCUMENTO" DataField="NumeroDoc">
                                    <ItemStyle Width="10%" />
                                    </asp:BoundField>
                                    <asp:BoundField HeaderText="CLIENTE" DataField="NombreCliente">
                                    <ItemStyle Width="30%" />
                                    </asp:BoundField>
                                    <asp:BoundField HeaderText="FECHA EMISION" DataField="FechaEmision">
                                    <ItemStyle Width="10%" />
                                    </asp:BoundField>
                                    <asp:BoundField HeaderText="MONTO TOT." DataField="montoTotal">
                                    <ItemStyle Width="10%" />
                                    </asp:BoundField>
                                    <asp:ButtonField Text="Consultar" />
                                </Columns>
                                </asp:GridView>
                             </DIV>
                         </TD>
                     </TR>
                     <tr><td style="height:10px"></td></tr>
                </TBODY>
           </TABLE>   
    
            <%--Controles de comando--%> 
            <table>
                <tr >
                    <td>              
                        <asp:ImageButton ID="imbCerrar" runat="server" 
                            ImageUrl="~/imagenes/bn_cerrar.jpg" onclick="imbCerrar_Click" />
                    </td>
                </tr>
            </table>            
    
    
            </div>

        </div>
        
    </div>
    </contenttemplate> </asp:UpdatePanel>
</form>
</body>
</html>
